| Regression test

> module Test (main) where

> import qualified Ply
> import qualified Bs
> import qualified OptBs
> import qualified Iv
> import Test.HUnit

> main :: IO ()  
> main = runTestTT tests >> return ()

> tests :: Test
> tests = TestList $
>   map (\(e,lu) -> TestLabel e $ TestCase $ do
>            c <- readFile ("examples/" ++ e)
>            let Ply.Named (x,ps) = read c
>            let bs = map Bs.ofPly ps :: [Bs.Bs Double]
>            (lu',_) <- OptBs.infIO bs (map snd x) 0.0001 0
>            lu' @?= lu)
>     [ ("beale",            Iv.iv (-6.247806756611761e-5) (3.2972127405009816e-5))
>     , ("booth",            Iv.iv (-5.340576171875e-5)    (8.58306884765625e-6))
>     , ("camelback",        Iv.iv (-3.0949288079362787)   (-3.0948380875801083))
>     , ("ferguson",         Iv.iv (2887.3557358971593)    (2887.3557358971593))
>     , ("goldstein_price",  Iv.iv (2.999948501586914)     (3.0))
>     , ("rosenbrock",       Iv.iv (-9.86470307301109e-5)  (0.0))
>     , ("colville",         Iv.iv (-8.616052400611807e-5) (1.3822748535119445e-5))
>     , ("gamma_pt",         Iv.iv 0                       0)
>     ]
